import request from '@/utils/request'

// 查询交易交割记录列表
export function listSettlement(query) {
    return request({
        url: '/stock/settlement/list',
        method: 'get',
        params: query
    })
}

// 删除交易交割记录
export function delSettlement(id) {
    return request({
        url: '/stock/settlement/' + id,
        method: 'delete'
    })
}


// 生成股票统计
export function generateStat(params) {
    return request({
        url: '/stock/settlement/generate',
        method: 'post',
        data: params
    })
}

// 查询交易详情列表
export function listStatSettlement(stockCode, accountTag) {
    return request({
        url: '/stock/settlement/stat_settlement_list',
        method: 'get',
        params: {
            stock_code: stockCode,
            account_tag: accountTag
        }
    })
}